package com.jjb.www.ui.adapter;

import android.content.Context;
import android.widget.TextView;

import com.jjb.www.R;
import com.jjb.www.bean.MessBean;
import com.xj.marqueeview.base.CommonAdapter;
import com.xj.marqueeview.base.ViewHolder;

import java.util.List;

/**
 * @author CRG
 * @date :2022/5/24 11:39
 * @description:
 */
public class HomeMessageAdapter extends CommonAdapter<MessBean> {
    public HomeMessageAdapter(Context context, int layoutId, List<MessBean> datas) {
        super(context, layoutId, datas);
    }

    @Override
    protected void convert(ViewHolder viewHolder, MessBean item, int position) {
        TextView mTvData =viewHolder.getView(R.id.tv_data);
        TextView mTvTime =viewHolder.getView(R.id.tv_time);
        mTvData.setText(item.getData());
//        mTvTime.setText(item.getTime()!=null&&item.getTime().length()>5?item.getTime().substring(5,item.getTime().length()):item.getTime());
    }
}



